% Package options:
%  ngerman
%  german
% You may access
%  \proofname
%  \begin{proof}[]
%   \qedhere
%   \raiseqed{}
%  \end{proof}%   <-- Please use a % sign here!
% from this document.
% When you combine my proof environment with ntheorem environments, use a nested structure as follows:
%  \begin{some-ntheorem}
%   some-lemma-text
%   \begin{proof}
%    some-proof-text
%   \end{proof}%
%  \end{some-ntheorem}
% File created by Stefan Krause -- version 1.0.
\RequirePackage{amssymb,ifthen}
\newcommand{\proofname}{Proof}
\DeclareOption{ngerman}{\renewcommand{\proofname}{Beweis}}
\DeclareOption{german}{\renewcommand{\proofname}{Beweis}}
\ProcessOptions
\newcommand{\qed}{\ensuremath{\Box}}
\newcommand{\proofqed}{}
\newenvironment{proof}[1][]{\normalfont\renewcommand{\proofqed}{\hspace*{\fill}\qed}%
 \par\smallskip\noindent\textbf{\proofname\ifthenelse{\equal{#1}{}}{}{ (#1)}}\quad}%
 {\proofqed\par\smallskip\noindent}
\newcommand{\qedhere}{\ifmmode\tag*{\qed}\else\proofqed\fi\xdef\proofqed{}}
\newcommand{\raiseqed}[1]{\vspace*{-#1}\proofqed\xdef\proofqed{}}

